#!/bin/sh

# create install dir
mkdir -p /usr/local/nagios/libexec/

# set perms & owner for utils file
chown root.root utils.php
chown nagios.nagios utils.php
chmod 644 utils.php

# copy utils file
cp -p utils.php /usr/local/nagios/libexec/

# set perms & owner for check files
chown root.root check_*
chown nagios.nagios check_*
chmod 755 check_*

# copy check files
cp -p check_* /usr/local/nagios/libexec/
